﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x02001121 RID: 4385
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class ServerPrefs : IMessage<ServerPrefs>, IMessage, IEquatable<ServerPrefs>, IDeepCloneable<ServerPrefs>, IBufferMessage
	{
		// Token: 0x17003791 RID: 14225
		// (get) Token: 0x0600C449 RID: 50249 RVA: 0x00212D18 File Offset: 0x00210F18
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<ServerPrefs> Parser
		{
			get
			{
				return ServerPrefs._parser;
			}
		}

		// Token: 0x17003792 RID: 14226
		// (get) Token: 0x0600C44A RID: 50250 RVA: 0x00212D1F File Offset: 0x00210F1F
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return ServerPrefsReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x17003793 RID: 14227
		// (get) Token: 0x0600C44B RID: 50251 RVA: 0x00212D31 File Offset: 0x00210F31
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return ServerPrefs.Descriptor;
			}
		}

		// Token: 0x0600C44C RID: 50252 RVA: 0x00212D38 File Offset: 0x00210F38
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ServerPrefs()
		{
		}

		// Token: 0x0600C44D RID: 50253 RVA: 0x00212D4B File Offset: 0x00210F4B
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ServerPrefs(ServerPrefs other) : this()
		{
			this.serverPrefsId_ = other.serverPrefsId_;
			this.data_ = other.data_;
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x0600C44E RID: 50254 RVA: 0x00212D7C File Offset: 0x00210F7C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ServerPrefs Clone()
		{
			return new ServerPrefs(this);
		}

		// Token: 0x17003794 RID: 14228
		// (get) Token: 0x0600C44F RID: 50255 RVA: 0x00212D84 File Offset: 0x00210F84
		// (set) Token: 0x0600C450 RID: 50256 RVA: 0x00212D8C File Offset: 0x00210F8C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint ServerPrefsId
		{
			get
			{
				return this.serverPrefsId_;
			}
			set
			{
				this.serverPrefsId_ = value;
			}
		}

		// Token: 0x17003795 RID: 14229
		// (get) Token: 0x0600C451 RID: 50257 RVA: 0x00212D95 File Offset: 0x00210F95
		// (set) Token: 0x0600C452 RID: 50258 RVA: 0x00212D9D File Offset: 0x00210F9D
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ByteString Data
		{
			get
			{
				return this.data_;
			}
			set
			{
				this.data_ = ProtoPreconditions.CheckNotNull<ByteString>(value, "value");
			}
		}

		// Token: 0x0600C453 RID: 50259 RVA: 0x00212DB0 File Offset: 0x00210FB0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as ServerPrefs);
		}

		// Token: 0x0600C454 RID: 50260 RVA: 0x00212DC0 File Offset: 0x00210FC0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(ServerPrefs other)
		{
			return other != null && (other == this || (this.ServerPrefsId == other.ServerPrefsId && !(this.Data != other.Data) && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x0600C455 RID: 50261 RVA: 0x00212E10 File Offset: 0x00211010
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.ServerPrefsId != 0U)
			{
				num ^= this.ServerPrefsId.GetHashCode();
			}
			if (this.Data.Length != 0)
			{
				num ^= this.Data.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x0600C456 RID: 50262 RVA: 0x00212E6A File Offset: 0x0021106A
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x0600C457 RID: 50263 RVA: 0x00212E72 File Offset: 0x00211072
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x0600C458 RID: 50264 RVA: 0x00212E7C File Offset: 0x0021107C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.Data.Length != 0)
			{
				output.WriteRawTag(98);
				output.WriteBytes(this.Data);
			}
			if (this.ServerPrefsId != 0U)
			{
				output.WriteRawTag(120);
				output.WriteUInt32(this.ServerPrefsId);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x0600C459 RID: 50265 RVA: 0x00212EDC File Offset: 0x002110DC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.ServerPrefsId != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.ServerPrefsId);
			}
			if (this.Data.Length != 0)
			{
				num += 1 + CodedOutputStream.ComputeBytesSize(this.Data);
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x0600C45A RID: 50266 RVA: 0x00212F38 File Offset: 0x00211138
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(ServerPrefs other)
		{
			if (other == null)
			{
				return;
			}
			if (other.ServerPrefsId != 0U)
			{
				this.ServerPrefsId = other.ServerPrefsId;
			}
			if (other.Data.Length != 0)
			{
				this.Data = other.Data;
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x0600C45B RID: 50267 RVA: 0x00212F8D File Offset: 0x0021118D
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x0600C45C RID: 50268 RVA: 0x00212F98 File Offset: 0x00211198
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num != 98U)
				{
					if (num != 120U)
					{
						this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
					}
					else
					{
						this.ServerPrefsId = input.ReadUInt32();
					}
				}
				else
				{
					this.Data = input.ReadBytes();
				}
			}
		}

		// Token: 0x04004F30 RID: 20272
		private static readonly MessageParser<ServerPrefs> _parser = new MessageParser<ServerPrefs>(() => new ServerPrefs());

		// Token: 0x04004F31 RID: 20273
		private UnknownFieldSet _unknownFields;

		// Token: 0x04004F32 RID: 20274
		public const int ServerPrefsIdFieldNumber = 15;

		// Token: 0x04004F33 RID: 20275
		private uint serverPrefsId_;

		// Token: 0x04004F34 RID: 20276
		public const int DataFieldNumber = 12;

		// Token: 0x04004F35 RID: 20277
		private ByteString data_ = ByteString.Empty;
	}
}
